package pattern19;

/**
 * 抽象的Command类，用来声明执行操作的接口
 * @author wdl
 */
public abstract class BaseCommand {
    protected Receiver receiver;

    /**
     * 设置一个命令接收者
     * @param receiver 接收者
     */
    public BaseCommand(Receiver receiver) {
        this.receiver = receiver;
    }

    /**
     * 执行请求
     */
    abstract public void execute();
}
